﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
    <link href="../../scripts/ligerUI/skins/Aqua/css/ligerui-all.css" rel="stylesheet" type="text/css" />
    <link href="../../scripts/ligerUI/skins/Gray/css/all.css" rel="stylesheet" type="text/css" />
    <link href="../../scripts/ligerUI/skins/ligerui-icons.css" rel="stylesheet" type="text/css" />
    <script src="../../scripts/jquery/jquery-1.3.2.min.js" type="text/javascript"></script>
    <script src="../../scripts/ligerUI/js/core/base.js" type="text/javascript"></script>
    <script src="../../scripts/ligerUI/js/plugins/ligerToolBar.js" type="text/javascript"></script>
    <script src="../../scripts/ligerUI/js/plugins/ligerDialog.js" type="text/javascript"></script>
    <script src="../../scripts/ligerUI/js/plugins/ligerGrid.js" type="text/javascript"></script> 
    <script src="../../scripts/ligerUI/js/plugins/ligerFilter.js" type="text/javascript"></script>
    <script src="../../scripts/ligerUI/js/plugins/ligerDrag.js" type="text/javascript"></script>
    <script src="../../scripts/ligerUI/js/plugins/ligerResizable.js" type="text/javascript"></script>
    <script src="ligerGrid.showFilter.js" type="text/javascript"></script>
    <script src="../grid/CustomersData.js" type="text/javascript"></script>
    <script type="text/javascript">

    //去掉  大于小于包括,并改变顺序
    $.ligerDefaults.Filter.operators['string'] =
    $.ligerDefaults.Filter.operators['text'] =
    ["like" , "equal", "notequal", "startwith", "endwith" ];

    //这个例子展示了本地过滤，你也可以在服务器端过滤(将过滤规则组成json，以一个参数提交给服务器)
    //相见ligerGrid.showFilter.js
        $(function ()
        {
            window['g'] = 
            $("#maingrid4").ligerGrid({
                columns: [
            { display: '主键', name: 'CustomerID', align: 'left', width: 120 },
            { display: '公司名', name: 'CompanyName', minWidth: 60, align: 'left' },
            { display: '联系名', name: 'ContactName', width: 120, align: 'left' },
            { display: '城市', name: 'City', heightAlign: 'center' },
            { display: '电话', name: 'Phone', width: 170, align: 'left' },
            { display: '传真', name: 'Fax', width: 170, align: 'left' } 
                ], data: $.extend(true,{},CustomersData), pageSize: 30,
                toolbar: { items: [{ text: '高级自定义查询', click: itemclick, icon: 'search2'}]
                },
                width: '90%', height: '80%', checkbox: false
            });
            $("#pageloading").hide();
        });
        function itemclick()
        {
            g.options.data = $.extend(true,{}, CustomersData);
            g.showFilter();
        }
    </script>
</head>
<body style="padding: 4px; overflow: hidden;">
    <div class="l-loading" style="display: block" id="pageloading">
    </div>
    <div id="maingrid4" style="margin: 0; padding: 0">
    </div>
    <div style="display: none;">
    </div>
</body>
</html>
